package com.caigou.modules.info.ui.rules

import android.os.Bundle
import com.alibaba.android.arouter.facade.annotation.Route
import com.alibaba.android.arouter.launcher.ARouter
import com.caigou.comm.base.constants.RouterPath
import com.caigou.comm.base.container.BaseActivity
import com.caigou.modules.info.databinding.ActivityInfoRulesBinding
import dagger.hilt.android.AndroidEntryPoint

/**
 * @author #Suyghur.
 * Created on 2021/11/26
 */
@Route(path = RouterPath.Info.PAGE_INFO_RULES)
@AndroidEntryPoint
class InfoRulesActivity : BaseActivity() {

    private lateinit var binding: ActivityInfoRulesBinding

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        binding = ActivityInfoRulesBinding.inflate(layoutInflater)
        setContentView(binding.root)
        containerId = binding.infoRulesLlContainer.id
        initView()
    }

    private fun initView() {
        ARouter.getInstance().inject(this)

        val sb = StringBuilder()
        sb.append("<html><head><meta http-equiv='content-type' content='text/html; charset=utf-8'>")
        sb.append("<meta charset='utf-8'  content='1'></head><body style='color: black'><p></p>")
        sb.append("<div style=\"text-align:center;\"><span style=\"font-size:24px;\">人人为我，我为人人</span></div>")
        sb.append(
            "<p><strong><span style=\"font-size:18px;color:#E53333;\">一</span><strong><span style=\"font-size:18px;color:#E53333;\">、</span></strong><span style=\"font-size:18px;color:#E53333;\">民间资料权限问题</span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">1、如何才能发布民间资料</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\"><br /></span></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\">答：等级达到<span style=\"color:#FF9900;\">{彩民专家}即可发布民间资料帖子</span></span></span></span></strong></span></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">2、如何才能售卖民间资料帖子</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\">答：<span style=\"color:#FF9900;\">等级达到{彩民专家}则可在发布页设置帖子售卖金额</span>，可设置图片试看张数，不可大于上传图片的张数（<span style=\"color:#FF9900;\">非必选</span>）</span></span></strong></span></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">3、最多能发布多少个作品</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\"><br /></span></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\">答：</span><span style=\"color:#000000;\">每个用户最多能发布<span style=\"color:#FF9900;\">20个作品</span></span></span></span></strong></span></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">4、最多能上传多少张图片</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\">答：为了满足彩民找料的问题，单个作品<span style=\"color:#FF9900;\">最多可上传100张图片</span></span></span></strong></span></p><p><strong><span style=\"color:#E53333;\"><span style=\"font-size:18px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"font-size:18px;\">二、平台功能问题</span></span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"font-size:18px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;\">1、平台能充值吗？</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\"><br /></span></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#EE33EE;\"><span style=\"color:#000000;\">答：平台还</span><span style=\"color:#FF9900;\">未开放充值通道</span><span style=\"color:#FF9900;\">（正在解决中...）</span></span></span></strong></span></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">2、刚注册的用户为什么会被禁言呢？</span></span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\">答：(1)新手只能在高手论坛<span style=\"color:#FF9900;\">港彩与澳彩发布帖子或评论 <span style=\"color:#000000;\">(2)</span></span>且每天只能发布1条帖子或评论1次<span style=\"color:#FF9900;\">（2选1）<strong><span style=\"color:#000000;\"><span style=\"font-size:18px;\">、</span></span></strong><span style=\"color:#000000;\"></span><span style=\"color:#000000;\">(</span></span>3)帖子或评论<span style=\"color:#FF9900;\">审核通过10次后</span>，则自动解除该限制</span></span></strong></p><p><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\"><br /></span></span></strong></p><p><strong><span style=\"color:#E53333;font-size:14px;\"><span style=\"color:#000000;font-size:14px;\">3、为什么会被禁言封号?</span></span></strong></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\"><br /></span></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><span style=\"color:#000000;\">答：(1)<span style=\"color:#FF9900;\">带有暴力、粗俗攻击性语言者</span>，禁言或封号 (2)<span style=\"color:#FF9900;\">公开联系方式者</span>，禁言或封号(3)<span style=\"color:#FF9900;\">网投拉人卖料打广告者</span>，封号  (4)、<span style=\"color:#FF9900;\">发布涉政，涉黄等违规信息者</span>，封号</span></span></strong></span></p><span><strong><span style=\"color:#E53333;\"><br /></span></strong></span><p><br /></p><p><span><strong><span style=\"color:#E53333;\"><br /></span></strong></span></p><p><span><strong><span style=\"color:#E53333;\"><br /></span></strong></span></p><p><br /></p>"
        )
        sb.append("</body></html>")
        binding.infoRulesWvContainer.settings.defaultTextEncodingName = "utf-8"
        binding.infoRulesWvContainer.loadDataWithBaseURL(null, sb.toString(), "text/html", "utf-8", null)

        binding.infoRulesTvBack.setOnClickListener {
            finish()
        }
    }
}